package com.hanhai.material.wages.entity;

import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.RelationManyToOne;
import com.mybatisflex.annotation.Table;
import java.io.Serializable;
import java.time.LocalDate;
import java.util.Date;
import java.util.List;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 *  实体类。
 *
 * @author youchuang
 * @since 2023/10/25 17:34:51
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(value = "ding_attendance_result")
public class DingAttendanceResult implements Serializable {

    /**
     * 考勤结果
     */
    @Id
    private String id;

    /**
     * 数据来源
     */
    private String sourceType;

    /**
     * 基准时间
     */
    private Date baseCheckTime;

    /**
     * 实际打卡时间
     */
    private Date userCheckTime;

    /**
     * 管理的审批实力id
     */
    private String procinstId;

    private Long approveId;

    /**
     * 位置结果：
   
   Normal：范围内
   
   Outside：范围外
   
   NotSigned：未打卡
     */
    private String locationResult;

    /**
     * 打卡结果：
   
   Normal：正常
   
   Early：早退
   
   Late：迟到
   
   SeriousLate：严重迟到
   
   Absenteeism：旷工迟到
   
   NotSigned：未打卡
     */
    private String timeResult;

    /**
     * 考勤类型：OnDuty:上班，OffDuty:下班
     */
    private String checkType;

    private String userId;

    /**
     * 工作日
     */
    private Date workDate;

    /**
     * 记录ID
     */
    private Long recordId;

    /**
     * 排班ID
     */
    private Long planId;

    /**
     * 考勤组ID
     */
    private Long groupId;

    /**
     * 创建时间
     */
    private Date createTime;

    @Column(ignore = true)
    private List<DingAttendanceResult> dingAttendanceResultList;

//   @RelationManyToOne(selfField = "userId",targetField = "userid",ex)
    @Column(ignore = true)
    private AttendanceResultReport attendanceResultReport;
    @Column(ignore = true)
    private LocalDate startDate;
    @Column(ignore = true)
    private LocalDate endDate;



}
